<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<link rel="stylesheet" type="text/css" href="../layui/dist/css/layui.css" />
	</head>

	<body>
		<script src="../layui/dist/layui.js" type="text/javascript" charset="utf-8"></script>

		<script>
			//config的设置是全局的
			layui.config({
				base: '/hongwei-test/layui/start/' //假设这是test.js所在的目录
			}).extend({ //设定模块别名
				test: 'test' //如果test.js是在根目录，也可以不用设定别名
			});

			//使用test
			layui.use('test', function() {
				
			});
			
		</script>
	</body>

</html>